# coding=utf-8
import sys
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
from matplotlib.pyplot import savefig  
path = sys.argv[1]
names_filename = sys.argv[2]
names = []
with open(names_filename, 'r') as f:
    line = f.readline()
    while line:
        line=line.rstrip('\n')
        elements = line.split(',')
        for element in elements:
            names.append(element)
        line = f.readline()
#将结果给names
ukdate = pd.read_csv(path, names=names)
df = ukdate.cumsum()
plt.figure()
df.plot.area()
savefig('/home/kirohuji/MyFig.jpg')  